package edu.del.newsreleasesystem.comfirm;

import lombok.Getter;
import org.springframework.amqp.rabbit.connection.CorrelationData;

/**
 * 自定义 CorrelationData，用于在消息发送时携带额外的信息：
 * - callbackBeanName：处理失败回调的 ConfirmCallbackService 实现类 Bean 名称
 * - message：原始业务消息对象（比如 NewsSyncMessage）
 */
@Getter
public class MyCorrelationData extends CorrelationData {

    private final String callbackBeanName;
    private final Object message;

    public MyCorrelationData(String id, String callbackBeanName, Object message) {
        super(id);
        this.callbackBeanName = callbackBeanName;
        this.message = message;
    }
}